﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;

namespace CastleDefender.ConfigFolder
{
    //Quy tắc đặt tên biến static [Tên Đối Tượng][Tên biến muốn thể hiện] vd: BowMaxPower : tên đối tượng Bow, tên biến thể hiện MaxPower
    public static class Config
    {
        //Game world
        public static Vector2 VectorG = new Vector2(0, 10);
        public static float PI = (float)Math.PI;
        public static Vector2 ScreenSize = new Vector2(800, 480); //kích thước của màn hình hiển thị
        public static Vector2 MapSize = new Vector2(800, 480);// kích thước của map game
        public static int GameSurFace = (int)MapSize.Y - 45;
        public static Rectangle GameBounds = new Rectangle(0, 0, (int)ScreenSize.X, GameSurFace - 30);
      
        //Init
        public static int InitMonsterStupid = 3;
        public static int InitMonsterFly = 0;
        public static int InitArrowNormal = 100;
        public static int InitArrowFire = 10;
        public static int InitArrowElectric = 10;
        public static int InitTimeCreateMonsterStupid = 7;
        public static int InitTimeCreateMonsterFly = 15;
        public static int TimeWaiting = 3;
        public static int InitPosYHighScore = 120;
        public static int InitPosXHighScore = 140;

        //Button
        public static int ButtonTimeSpan = 100;

        //Folder Resource
        public static string FolderObject = @"ObjectTexture\";
        public static string FolderArrows = @"Arrows\";
        public static string FolderItems = @"Items\";
        public static string FolderMenus = @"Menus\";
        public static string FolderMonsters = @"Monsters\";
        public static string FolderButtons = @"Buttons\";
        public static string FolderFonts = @"Fonts\";
        public static string FolderBackgrounds = @"Backgrounds\";
        public static string ConnectionString = @"Data Source= 'isostore:/GameData.sdf'; File Mode = read write;";

        //Menu
        public static int MenuMarginY = 10;
        public static int MenuPosYInit = 120;
        public static int MenuMarginX = 80;

        //Bow
        public static int BowMaxPower = 100;
        public static int BowCountColumnFrame = 6;
        public static int BowDeltaPower = BowMaxPower / BowCountColumnFrame;
        public static int BowAttackState = 0;
        public static Vector2 BowInitPosition = new Vector2(400, 305);
        public static int BowHeartCastle = 2000;

        //Arrow
        public static int ArrowWidthSpearHead = 4;
        public static int ArrowHeightSpearHead = 4;
        public static int ArrowTimeAnimation = 100;
        public static float ArrowTimeInOrbit = 0.11f;
        public static int ArrowTimeSpanMotion = 1;
        public static int ArrowTimeFreeze = 5;

        //Camera
        public static Vector2 CameraDefaultPosition = new Vector2(800, 480);

        //Monster
        public static int MonsterTimeChangeFrame = 170;
        public static int MonsterSpeedEffect = 100;
        public static int MonsterSafeDistance = 5; //khoảng cách an toàn để đảm bảo sprite ko bị che khuất khi va chạm
        public static int MonsterMaxIndexTextureMonsterStupid = 0;
        public static int MonsterMaxIndexTextureMonsterFly = 0;
        public static int MonsterLifeMonsterStupid = 90;
        public static int MonsterLifeMonsterFly = 110;
        public static int MonsterSpeedMonsterStupid = 4;
        public static int MonsterSpeedMonsterFly = 4;
        public static int MonsterMoveStepFast = 4;
        public static int MonsterMoveStepNormal = 3;
        public static int MonsterMoveStepSlow = 2;
        public static int MonsterMoveStepVerySlow = 1;
        public static int MonsterFlyLimitPosXMax = 200;
        public static int MonsterStupidDame = 1;
        public static int MonsterFlyDame = 10;
        public static int MonsterStupidScore = 10;
        public static int MonsterFlyScore = 50;

        //Monster State
        public static int StateMove = 0;
        public static int StateStandby = 1;
        public static int StateAttacked = 2;
        public static int StateDead = 3;

        //Item
        public static int ItemTimeAnimation = 100;
        public static int ItemTimeSpanCreateNewItem = 9;
        public static int ItemTimeDestroy = 12;
        public static int ItemMaxAmount = 50;
        public static int ItemMaxHeart = 100;
        public static int ItemTimeEffect = 4;
        public static int ItemRateStupidItem = 30; //Tỷ lệ xuất hiện item cản trở từ 0 đến 10 tương ứng cho 0 - 100%
        public static int ItemMaxStupidItem = 2;

        //Game bar
        public static Vector2 GameBarMargin = new Vector2(0, 55);
        
    }
}
